#include "link.h"


Link::Link(PixelProcessor * linkA, PixelProcessor * linkB)
{
  ProcessorLinkA = linkA;
  ProcessorLinkB = linkB;
}

Link::~Link(void)
{
}

void Link::SetDataLine(bool bit)
{
  /* or linked processor data */
  bDataLine = (ProcessorLinkA->GetClockedDataBit() | ProcessorLinkB->GetClockedDataBit());
  
  /* line set callbacks for syncronization */
  ProcessorLinkA->SetDataLine(bDataLine);
  ProcessorLinkB->SetDataLine(bDataLine);
}

void Link::ResetDataLine(void)
{
  bDataLine = 0;
}

bool Link::ReadDataLine(void)
{
  return bDataLine;
}
